package com.yunqi.autovender.receiver;

import android.content.BroadcastReceiver;
import android.content.Context;
import android.content.Intent;
import android.widget.Toast;

import com.yunqi.autovender.activity.MainActivity;

public class BootReceiver extends BroadcastReceiver {
    @Override
    public void onReceive(Context context, Intent intent) {
//        if(intent.getAction().equals("android.intent.action.BOOT_COMPLETED")) {
//            Toast.makeText(context,"监听到开机自启动广播",Toast.LENGTH_LONG).show();
//            Intent mIntent = new Intent(context, MainActivity.class);
//            mIntent.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK|Intent.FLAG_ACTIVITY_CLEAR_TOP);
//            context.startActivity(mIntent);
//        }
    }
}